export function backendMenus(user?: IUser): Array<IMenu> {
  const parent = user?.number ?? 'backendrouter'

  return [
    {
      key: '/' + parent, name: '后台路由', redirect: parent + '/userList', component: () => import('@/views-backend/home.vue'),
      children: [
        // { key: 'personnelList', name: '人员管理', component: () => import('@/views-backend/personnel-list/personnel-list.vue') },
        { key: 'userList', name: '用户管理', component: () => import('@/views-backend/user-list/user-list.vue') },
        { key: 'subscribeList', name: '预约管理', component: () => import('@/views-backend/subscribe-list/subscribe-list.vue') },
        { key: 'newList', name: '新闻管理', component: () => import('@/views-backend/new-list/new-list.vue') },
        { key: 'outpatientList', name: '门诊管理', component: () => import('@/views-backend/outpatient-list/outpatient-list.vue') },
      ],
    },
  ]
}
